home *** CD-ROM | disk | FTP | other *** search
/ POINT Software Programming / PPROG1.ISO / pascal / swag / ansi.swg / 0010_Display THEDRAW Images.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  1993-05-28  |  807 b   |  26 lines

  1. {
  2. > if you save as Pascal, and follow the instructions in the manual For
  3. > TheDraw everything will work fine. It is also much more efficient then
  4. > using normal ANSI-Files, since TheDraw-Pascal Files can be Compressed...
  5. }
  6. Var
  7.   VideoSeg : Word;
  8.  
  9. Procedure VisTheDrawImage(x, y, Depth, Width: Byte; Var Picture);
  10. Var
  11.   c       : Byte;
  12.   scrpos  : Word;
  13. begin
  14.   Dec(y);
  15.   Dec(x);
  16.   ScrPos := y * (ScrCol Shl 1) + x * 2;
  17.   For c := 0 to Depth-1 Do
  18.     Move(Mem[Seg(Picture) : ofs(Picture) + c * (Width Shl 1)],
  19.          Mem[VideoSeg : c * (ScrCol Shl 1) + ScrPos], Width Shl 1);
  20. end;
  21.  
  22. {
  23. if you picture is not crunched you can use this routine to show them With
  24. VideoSeg has to be $B000 or $B800, then use the Vars from the generated
  25. picture and insert when you call that procedure.
  26. }